<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
    <meta name="description" content="Metro, a sleek, intuitive, and powerful framework for faster and easier web development for Windows Metro Style.">
    <meta name="keywords" content="HTML, CSS, JS, JavaScript, framework, metro, front-end, frontend, web development">
    <meta name="author" content="Sergey Pimenov and Metro UI CSS contributors">

    <link rel='shortcut icon' type='image/x-icon' href='favicon.ico' />
    <title>Form &amp; Inputs :: Metro UI CSS - The front-end framework for developing projects on the web in Windows Metro Style</title>

    <link href="css/metro.css" rel="stylesheet">
    <link href="css/metro-icons.css" rel="stylesheet">
    <link href="css/metro-responsive.css" rel="stylesheet">
    <link href="css/metro-schemes.css" rel="stylesheet">

    <link href="css/docs.css" rel="stylesheet">

    <script src="js/jquery-2.1.3.min.js"></script>
    <script src="js/metro.js"></script>
    <script src="js/docs.js"></script>
    <script src="js/prettify/run_prettify.js"></script>
    <script src="js/ga.js"></script>
    <script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>

</head>
<body>
    <div class="container page-content">
        <h1><a href="index.html" class="nav-button transform"><span></span></a>&nbsp;Inputs</h1>

        @@adsense

        <div class="margin20 no-margin-left no-margin-right sub-header text-light">
            Metro UI CSS provides tools for styling input fields. Such as: text, password, checkbox, switch, etc.
            The input elements are formed from the outer container, the input element and auxiliary elements. This allows you to style the input elements, and give them additional futures.
        </div>

        <h4>Text &amp;  password</h4>
        <div class="example" data-text="example">
            <div class="grid">
                <div class="row cells2">
                    <div class="cell">
                        <label>Simple input text</label>
                        <div class="input-control text full-size">
                            <input type="text">
                        </div>
                    </div>
                    <div class="cell">
                        <label>Simple input password</label>
                        <div class="input-control password full-size">
                            <input type="password">
                        </div>
                    </div>
                </div>
                <div class="row cells2">
                    <div class="cell">
                        <label>Input with placeholder</label>
                        <div class="input-control text full-size">
                            <input type="text" placeholder="Input you text here...">
                        </div>
                    </div>
                    <div class="cell">
                        <label>Readonly input</label>
                        <div class="input-control text full-size">
                            <input type="text" readonly value="Metro UI CSS">
                        </div>
                    </div>
                </div>
                <div class="row cells2">
                    <div class="cell">
                        <label>Disabled input</label>
                        <div class="input-control text full-size">
                            <input type="text" disabled value="Metro UI CSS">
                        </div>
                    </div>
                    <div class="cell">
                        <label>Disabled input with placeholder</label>
                        <div class="input-control text full-size">
                            <input type="text" disabled placeholder="Input you text">
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <div class="example" data-text="code">
            <pre class="prettyprint linenums"><code>
                &lt;!-- input[type=text] --&gt;
                &lt;div class="input-control text"&gt;
                    &lt;input type="text"&gt;
                &lt;/div&gt;

                &lt;!-- input[type=password] --&gt;
                &lt;div class="input-control password"&gt;
                    &lt;input type="password"&gt;
                &lt;/div&gt;

                &lt;!-- input with placeholder --&gt;
                &lt;div class="input-control text"&gt;
                    &lt;input type="text" placeholder="Input you text here..."&gt;
                &lt;/div&gt;

                &lt;!-- readonly input --&gt;
                &lt;div class="input-control text"&gt;
                    &lt;input type="text" readonly&gt;
                &lt;/div&gt;

                &lt;!-- disabled input --&gt;
                &lt;div class="input-control text"&gt;
                    &lt;input type="text" disabled&gt;
                &lt;/div&gt;
            </code></pre>
        </div>

        <h4>Checkboxes &amp; Radio buttons</h4>
        <div class="example" data-text="example">
            <div class="grid">
                <div class="row cells2">
                    <div class="cell">
                        <h5>Checkboxes</h5>
                        <label class="input-control checkbox">
                            <input type="checkbox" checked>
                            <span class="check"></span>
                            <span class="caption">Check me</span>
                        </label>
                        <label class="input-control checkbox">
                            <input type="checkbox" disabled>
                            <span class="check"></span>
                            <span class="caption">Check me</span>
                        </label>
                        <label class="input-control checkbox">
                            <input type="checkbox" disabled checked>
                            <span class="check"></span>
                            <span class="caption">Check me</span>
                        </label>
                        <h5>Small checkboxes</h5>
                        <label class="input-control checkbox small-check">
                            <input type="checkbox" checked>
                            <span class="check"></span>
                            <span class="caption">Check me</span>
                        </label>
                        <label class="input-control checkbox small-check">
                            <input type="checkbox" disabled>
                            <span class="check"></span>
                            <span class="caption">Check me</span>
                        </label>
                        <label class="input-control checkbox small-check">
                            <input type="checkbox" disabled checked>
                            <span class="check"></span>
                            <span class="caption">Check me</span>
                        </label>
                        <h5>indeterminate</h5>
                        <label class="input-control checkbox">
                            <input type="checkbox" checked data-show="indeterminate">
                            <span class="check"></span>
                            <span class="caption">Check me</span>
                        </label>
                        <label class="input-control checkbox">
                            <input type="checkbox" data-show="indeterminate" disabled>
                            <span class="check"></span>
                            <span class="caption">Check me</span>
                        </label>
                        <h5>indeterminate small-check</h5>
                        <label class="input-control checkbox small-check">
                            <input type="checkbox" checked data-show="indeterminate">
                            <span class="check"></span>
                            <span class="caption">Check me</span>
                        </label>
                        <label class="input-control checkbox small-check">
                            <input type="checkbox" data-show="indeterminate" disabled>
                            <span class="check"></span>
                            <span class="caption">Check me</span>
                        </label>
                    </div>
                    <div class="cell">
                        <h5>Radio buttons</h5>
                        <label class="input-control radio">
                            <input type="radio" name="n1" checked>
                            <span class="check"></span>
                            <span class="caption">Select me</span>
                        </label>
                        <label class="input-control radio">
                            <input type="radio" name="n1">
                            <span class="check"></span>
                            <span class="caption">Select me</span>
                        </label>
                        <label class="input-control radio">
                            <input type="radio" name="n2" disabled>
                            <span class="check"></span>
                            <span class="caption">Select me</span>
                        </label>
                        <label class="input-control radio">
                            <input type="radio" name="n2" disabled checked>
                            <span class="check"></span>
                            <span class="caption">Select me</span>
                        </label>
                        <h5>Small radio buttons</h5>
                        <label class="input-control radio small-check">
                            <input type="radio" name="n3" checked>
                            <span class="check"></span>
                            <span class="caption">Select me</span>
                        </label>
                        <label class="input-control radio small-check">
                            <input type="radio" name="n3">
                            <span class="check"></span>
                            <span class="caption">Select me</span>
                        </label>
                        <label class="input-control radio small-check">
                            <input type="radio" name="n4" disabled>
                            <span class="check"></span>
                            <span class="caption">Select me</span>
                        </label>
                        <label class="input-control radio small-check">
                            <input type="radio" name="n4" disabled checked>
                            <span class="check"></span>
                            <span class="caption">Select me</span>
                        </label>
                    </div>
                </div>
            </div>
        </div>

        <div class="example" data-text="code">
            <pre class="prettyprint linenums"><code>
                &lt;!-- Checkbox --&gt;
                &lt;label class="input-control checkbox"&gt;
                    &lt;input type="checkbox" checked&gt;
                    &lt;span class="check"&gt;&lt;/span&gt;
                    &lt;span class="caption"&gt;Checkbox&lt;/span&gt;
                &lt;/label&gt;

                &lt;!-- Small Checkbox --&gt;
                &lt;label class="input-control checkbox small-check"&gt;
                    &lt;input type="checkbox" checked&gt;
                    &lt;span class="check"&gt;&lt;/span&gt;
                    &lt;span class="caption"&gt;Checkbox&lt;/span&gt;
                &lt;/label&gt;

                &lt;!-- Radio button --&gt;
                &lt;label class="input-control radio"&gt;
                    &lt;input type="radio"&gt;
                    &lt;span class="check"&gt;&lt;/span&gt;
                    &lt;span class="caption"&gt;Radio&lt;/span&gt;
                &lt;/label&gt;

                &lt;!-- Small radio button --&gt;
                &lt;label class="input-control radio small-check"&gt;
                    &lt;input type="radio"&gt;
                    &lt;span class="check"&gt;&lt;/span&gt;
                    &lt;span class="caption"&gt;Small radio&lt;/span&gt;
                &lt;/label&gt;
            </code></pre>
        </div>

        <h4>Switchers (checkbox variation)</h4>
        <div class="example" data-text="example">
            <div class="grid">
                <div class="row cells2">
                    <div class="cell">
                        <h5>Modern Switchers</h5>
                        <label class="switch">
                            <input type="checkbox" checked>
                            <span class="check"></span>
                        </label>
                        <label class="switch">
                            <input type="checkbox" >
                            <span class="check"></span>
                        </label>
                        <label class="switch">
                            <input type="checkbox" disabled>
                            <span class="check"></span>
                        </label>
                        <label class="switch">
                            <input type="checkbox" disabled checked>
                            <span class="check"></span>
                        </label>
                    </div>
                    <div class="cell">
                        <h5>Original Switchers</h5>
                        <label class="switch-original">
                            <input type="checkbox" checked>
                            <span class="check"></span>
                        </label>
                        <label class="switch-original">
                            <input type="checkbox" >
                            <span class="check"></span>
                        </label>
                        <label class="switch-original">
                            <input type="checkbox" disabled>
                            <span class="check"></span>
                        </label>
                        <label class="switch-original">
                            <input type="checkbox" disabled checked>
                            <span class="check"></span>
                        </label>
                    </div>
                </div>
            </div>
        </div>

        <div class="example" data-text="code">
            <pre class="prettyprint linenums"><code>
                &lt;!-- Modern switch --&gt;
                &lt;label class="switch"&gt;
                    &lt;input type="checkbox"&gt;
                    &lt;span class="check"&gt;&lt;/span&gt;
                &lt;/label&gt;

                &lt;!-- Original switch --&gt;
                &lt;label class="switch-original"&gt;
                    &lt;input type="checkbox"&gt;
                    &lt;span class="check"&gt;&lt;/span&gt;
                &lt;/label&gt;
            </code></pre>
        </div>

        <h4>Textarea</h4>
        <div class="example" data-text="example">
            <div class="grid">
                <div class="row cells3">
                    <div class="cell">
                        <h5>Default</h5>
                        <div class="input-control textarea full-size">
                            <textarea></textarea>
                        </div>
                    </div>
                    <div class="cell">
                        <h5>Auto resize height</h5>
                        <div class="input-control textarea full-size" data-role="input" data-text-auto-resize="true">
                            <textarea></textarea>
                        </div>
                    </div>
                    <div class="cell">
                        <h5>Auto resize with max height</h5>
                        <div class="input-control textarea full-size" data-role="input" data-text-auto-resize="true" data-text-max-height="200">
                            <textarea></textarea>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <div class="example" data-text="code">
            <pre class="prettyprint linenums"><code>
                &lt;div class="input-control textarea"&gt;
                    &lt;textarea&gt;&lt;/textarea&gt;
                &lt;/div&gt;
                &lt;div class="input-control textarea"
                    data-role="input" data-text-auto-resize="true"&gt;
                    &lt;textarea&gt;&lt;/textarea&gt;
                &lt;/div&gt;
                &lt;div class="input-control textarea"
                    data-role="input" data-text-auto-resize="true" data-text-max-height="200"&gt;
                    &lt;textarea&gt;&lt;/textarea&gt;
                &lt;/div&gt;
            </code></pre>
        </div>

        <h4>Select</h4>
        <div class="example" data-text="example">
            <div class="grid">
                <div class="row cells2">
                    <div class="cell">
                        <h5>Select</h5>
                        <div class="input-control select full-size">
                            <select>
                                <option>1</option>
                                <option>2</option>
                                <option>3</option>
                            </select>
                        </div>
                    </div>
                    <div class="cell">
                        <h5>Select with multiply</h5>
                        <div class="input-control select multiple full-size" style="height: 100px">
                            <select multiple>
                                <option>1</option>
                                <option>2</option>
                                <option>3</option>
                                <option>4</option>
                            </select>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <div class="example" data-text="code">
            <pre class="prettyprint linenums"><code>
                &lt;div class="input-control select"&gt;
                    &lt;select&gt;
                        &lt;option&gt;1&lt;/option&gt;
                        &lt;option&gt;2&lt;/option&gt;
                        &lt;option&gt;3&lt;/option&gt;
                    &lt;/select&gt;
                &lt;/div&gt;
            </code></pre>
        </div>

        <div class="padding10 text-small bg-grayLighter">
            Metro UI CSS now supported thrid-party Select2.js plugin. We recomended use it
        </div>

        <h4>Input file</h4>
        <div class="example" data-text="example">
            <div class="grid">
                <div class="row cells3">
                    <div class="cell">
                        <label>Button with icon font</label>
                        <div class="input-control file full-size" data-role="input">
                            <input type="file">
                            <button class="button"><span class="mif-folder"></span></button>
                        </div>
                    </div>
                    <div class="cell">
                        <label>Button with image</label>
                        <div class="input-control file full-size" data-role="input">
                            <input type="file">
                            <button class="button"><img src="images/Blank_Folder.png"></button>
                        </div>
                    </div>
                    <div class="cell">
                        <label>Disabled input</label>
                        <div class="input-control file full-size" data-role="input">
                            <input type="file" disabled>
                            <button class="button"><img src="images/Blank_Folder.png"></button>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <p class="padding10 bg-grayLighter text-secondary">
            This future require <span class="tag alert">data-role="input"</span> attribute.
        </p>

        <div class="example" data-text="code">
            <pre class="prettyprint linenums"><code>
                &lt;div class="input-control file" data-role="input"&gt;
                    &lt;input type="file"&gt;
                    &lt;button class="button"&gt;&lt;span class="mif-folder"&gt;&lt;/span&gt;&lt;/button&gt;
                &lt;/div&gt;
            </code></pre>
        </div>

        <h4>Input buttons</h4>
        <div class="example" data-text="example">
            <br />
            <input type="button" value="Button">
            <input type="reset" value="Reset">
            <input type="submit" value="Submit">
            <br />
            <br />
        </div>

        <div class="example" data-text="code">
            <pre class="prettyprint linenums"><code>
                &lt;input type="button" value="Button"&gt;
                &lt;input type="reset" value="Reset"&gt;
                &lt;input type="submit" value="Submit"&gt;
            </code></pre>
        </div>

        <h4>Text field states</h4>
        <div class="example" data-text="example">
            <div class="grid">
                <div class="row cells4">
                    <div class="cell">
                        <label class="block">.error</label>
                        <div class="input-control text error">
                            <input type="text">
                        </div>
                    </div>
                    <div class="cell">
                        <label class="block">.warning</label>
                        <div class="input-control text warning">
                            <input type="text">
                        </div>
                    </div>
                    <div class="cell">
                        <label class="block">.success</label>
                        <div class="input-control text success">
                            <input type="text">
                        </div>
                    </div>
                    <div class="cell">
                        <label class="block">.required</label>
                        <div class="input-control text info">
                            <input type="text">
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <div class="example" data-text="code">
            <pre class="prettyprint linenums"><code>
                &lt;div class="input-control text error"&gt;
                    &lt;input type="text"&gt;
                &lt;/div&gt;

                &lt;div class="input-control text warning"&gt;
                    &lt;input type="text"&gt;
                &lt;/div&gt;

                &lt;div class="input-control text success"&gt;
                    &lt;input type="text"&gt;
                &lt;/div&gt;

                &lt;div class="input-control text info"&gt;
                    &lt;input type="text"&gt;
                &lt;/div&gt;
            </code></pre>
        </div>

        <h4>Input with prepend icon</h4>
        <div class="example" data-text="example">
            <br/>
            <div class="input-control text full-size">
                <span class="mif-user prepend-icon"></span>
                <input type="text">
            </div>
            <br/>
            <br/>
        </div>

        <div class="example" data-text="code">
            <pre class="prettyprint linenums"><code>
                &lt;div class="input-control text"&gt;
                    &lt;label&gt;Prepend icon&lt;/label&gt;
                    &lt;span class="mif-user prepend-icon"&gt;&lt;/span&gt;
                    &lt;input type="text"&gt;
                &lt;/div&gt;

                &lt;div class="input-control text"&gt;
                    &lt;label&gt;Prepend icon&lt;/label&gt;
                    &lt;img src="..." class="prepend-icon"&gt;
                    &lt;input type="text"&gt;
                &lt;/div&gt;
            </code></pre>
        </div>

        <h4>Big input</h4>
        <div class="example" data-text="example">
            <br/>
            <div class="input-control text big-input full-size">
                <input type="text">
            </div>
            <br/>
            <br/>
        </div>

        <div class="example" data-text="code">
            <pre class="prettyprint linenums"><code>
                &lt;div class="input-control text big-input"&gt;
                    &lt;input type="text"&gt;
                &lt;/div&gt;
            </code></pre>
        </div>

        <h4>Inputs with helper buttons (clear &amp; reveal)</h4>
        <div class="example" data-text="example">
            <div class="grid">
                <div class="row cells2">
                    <div class="cell">
                        <label>Input text with clear helper</label>
                        <div class="input-control text full-size" data-role="input">
                            <input type="text">
                            <button class="button helper-button clear"><span class="mif-cross"></span></button>
                        </div>
                    </div>
                    <div class="cell">
                        <label>Input password with reveal helper</label>
                        <div class="input-control password full-size" data-role="input">
                            <input type="password">
                            <button class="button helper-button reveal"><span class="mif-looks"></span></button>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <p class="padding10 bg-grayLighter text-secondary">
            This future require <span class="tag alert">data-role="input"</span> attribute.
        </p>

        <div class="example" data-text="code">
            <pre class="prettyprint linenums"><code>
                &lt;!-- Input with clear helper --&gt;
                &lt;div class="input-control text" data-role="input"&gt;
                    &lt;input type="text"&gt;
                    &lt;button class="button helper-button clear"&gt;&lt;span class="mif-cross"&gt;&lt;/span&gt;&lt;/button&gt;
                &lt;/div&gt;

                &lt;!-- Input with reveal helper --&gt;
                &lt;div class="input-control password" data-role="input"&gt;
                    &lt;input type="text"&gt;
                    &lt;button class="button helper-button reveal"&gt;&lt;span class="mif-looks"&gt;&lt;/span&gt;&lt;/button&gt;
                &lt;/div&gt;
            </code></pre>
        </div>

        <h4>Input with button(s)</h4>
        <div class="example" data-text="example">
            <label>Input with button</label>
            <div class="input-control text full-size" data-role="input">
                <input type="text">
                <button class="button"><span class="mif-search"></span></button>
            </div>

            <label>Input with button group</label>
            <div class="input-control text full-size" data-role="input">
                <input type="text">
                <div class="button-group">
                    <button class="button"><img src="images/location.png"></button>
                    <button class="button"><img src="images/group.png"></button>
                    <button class="button"><img src="images/power.png"></button>
                </div>
            </div>
        </div>

        <div class="example" data-text="code">
            <pre class="prettyprint linenums"><code>
                &lt;div class="input-control text" data-role="input"&gt;
                    &lt;input type="text"&gt;
                    &lt;button class="button"&gt;&lt;span class="mif-search"&gt;&lt;/span&gt;&lt;/button&gt;
                &lt;/div&gt;

                &lt;div class="input-control text" data-role="input"&gt;
                    &lt;input type="text"&gt;
                    &lt;div class="button-group"&gt;
                        &lt;button class="button"&gt;&lt;img src="images/location.png"&gt;&lt;/button&gt;
                        &lt;button class="button"&gt;&lt;img src="images/group.png"&gt;&lt;/button&gt;
                        &lt;button class="button"&gt;&lt;img src="images/power.png"&gt;&lt;/button&gt;
                    &lt;/div&gt;
                &lt;/div&gt;
            </code></pre>
        </div>

        <h4>Modern inputs</h4>
        <div class="example" data-text="example">
            <div class="grid">
                <div class="row cells3">
                    <div class="cell">
                        <div class="input-control modern text " data-role="input">
                            <input type="text">
                            <span class="label">You login</span>
                            <span class="informer">Please enter you login or email</span>
                            <span class="placeholder">Input login</span>
                        </div>
                    </div>
                    <div class="cell">
                        <div class="input-control modern text iconic" data-role="input">
                            <input type="text">
                            <span class="label">You login</span>
                            <span class="informer">Please enter you login or email</span>
                            <span class="placeholder">Input login</span>
                            <span class="icon mif-user"></span>
                        </div>
                    </div>
                    <div class="cell">
                        <div class="input-control modern password iconic " data-role="input">
                            <input type="password">
                            <span class="label">You password</span>
                            <span class="informer">Please enter you password</span>
                            <span class="placeholder">Input password</span>
                            <span class="icon mif-lock"></span>
                            <button class="button helper-button reveal"><span class="mif-looks"></span></button>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <div class="example" data-text="code">
            <pre class="prettyprint linenums"><code>
                &lt;div class="input-control modern text"&gt;
                    &lt;input type="text"&gt;
                    &lt;span class="label"&gt;You login&lt;/span&gt;
                    &lt;span class="informer"&gt;Please enter you login or email&lt;/span&gt;
                    &lt;span class="placeholder"&gt;Input login&lt;/span&gt;
                &lt;/div&gt;

                &lt;div class="input-control modern text iconic"&gt;
                    &lt;input type="text"&gt;
                    &lt;span class="label"&gt;You login&lt;/span&gt;
                    &lt;span class="informer"&gt;Please enter you login or email&lt;/span&gt;
                    &lt;span class="placeholder"&gt;Input login&lt;/span&gt;
                    &lt;span class="icon mif-user"&gt;&lt;/span&gt;
                &lt;/div&gt;

                &lt;div class="input-control modern password iconic" data-role="input"&gt;
                    &lt;input type="password"&gt;
                    &lt;span class="label"&gt;You password&lt;/span&gt;
                    &lt;span class="informer"&gt;Please enter you password&lt;/span&gt;
                    &lt;span class="placeholder"&gt;Input password&lt;/span&gt;
                    &lt;span class="icon mif-lock"&gt;&lt;/span&gt;
                    &lt;button class="button helper-button reveal"&gt;&lt;span class="mif-looks"&gt;&lt;/span&gt;&lt;/button&gt;
                &lt;/div&gt;
            </code></pre>
        </div>

        <h4 id="_input-range_">Input range</h4>
        <div class="example" data-text="example">
            <div class="grid">
                <div class="row cells2">
                    <div class="cell">
                        <h5>Default</h5>
                        <div class="input-control range full-size">
                            <input type="range">
                        </div>
                    </div>
                    <div class="cell">
                        <h5>With subclass <span class="tag">big-input</span></h5>
                        <div class="input-control range big-input full-size">
                            <input type="range">
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <div class="example" data-text="code">
            <pre class="prettyprint linenums no-scroll-x"><code>
                &lt;div class="input-control range"&gt;
                    &lt;input type="range"&gt;
                &lt;/div&gt;

                &lt;div class="input-control range big-input"&gt;
                    &lt;input type="range"&gt;
                &lt;/div&gt;
            </code></pre>
        </div>
    </div>

    @@hit

</body>
</html>